<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <input id="c-anchang_id" type="hidden" name="row[anchang_id]" value="{$anchang_id}">
    <input id="c-task_id" type="hidden" name="row[task_id]" value="{$task_id}">

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('所屬案場')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input readonly class="form-control" type="text" value="{$anchangname}">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('工作事項')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input readonly class="form-control" type="text" value="{$taskname}">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('提醒日期')}:</label>
        <div class="col-xs-6 col-sm-4">
            <input id="c-remind_date" class="form-control datetimepicker" data-date-format="YYYY-MM-DD" data-use-current="true" name="row[remind_date]" type="text" value="{$task.remind_date}">
        </div>
        <label id="c-weekinfo" style="padding: 5px"></label>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('幾天後重新提醒')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-replay" data-rule="required" class="form-control" name="row[replay]" type="number" value="{$task.replay}">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('提醒类型')}:</label>
        <div class="col-xs-12 col-sm-8">

            <div class="radio">
                {foreach name="taskStatusList" item="vo"}
                <label for="row[task_status]-{$key}"><input id="row[task_status]-{$key}" name="row[task_status]" type="radio" value="{$key}" {in name="key" value="$task.task_status"}checked{/in} /> {$vo}</label>
                {/foreach}
            </div>

        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('工作內容')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-taskcontent" readonly class="form-control editor" rows="5" name="row[content]" cols="50">{$task.content}</textarea>
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">歷史記錄:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-content0" readonly class="form-control editor" rows="10"  cols="100">{$content0}</textarea>
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('工作紀錄')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-content" class="form-control editor" rows="3" name="row[content]" cols="50">{$content1}</textarea>
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">圖片組:</label>
        <div class="col-xs-12 col-sm-8">
            <div class="input-group">
                <input id="c-images0" class="form-control" size="50" type="text" name="row[images]" value="{$task.images}">
                <div class="input-group-addon no-border no-padding">
                    <span><button type="button" id="plupload-images0" class="btn btn-danger plupload" data-input-id="c-images0" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp" data-multiple="true" data-preview-id="p-images0"><i class="fa fa-upload"></i> </button></span>
                </div>
                <span class="msg-box n-right" for="c-images0"></span>
            </div>
            <ul class="row list-inline plupload-preview" id="p-images0"></ul>
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Acdevice_ids')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-acdevice_ids" data-rule="" data-source="jdy/acdevice/index" data-multiple="true" data-params='{$acdeviceparams}' class="form-control selectpage" name="row[acdevice_ids]" type="text" value="{$task.acdevice_ids}">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Baogu')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-baogu" data-rule="required" class="form-control" name="row[baogu]" type="number" value="{$task.baogu}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('保固日期')}:</label>
        <div class="col-xs-2 col-sm-2">
            <input id="c-baogu_start" class="form-control datetimepicker" data-date-format="YYYY-MM-DD" data-use-current="true" name="row[baogu_start]" type="text" value="{$task.baogu_start}">
        </div>
        <label class="col-xs-1 col-sm-1" style="padding: 1px;font-size: 20px;text-align: center">~</label>
        <div class="col-xs-2 col-sm2">
            <input id="c-baogu_end" class="form-control " readonly name="row[baogu_end]" type="text" value="{$task.baogu_end}">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">報價單號:</label>
        <div class="col-xs-12 col-sm-8">
            <input  class="form-control" type="text" name="row[quotation_no]" value="{$task.quotation_no}">
        </div>
    </div>


    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">工單單號:</label>
        <div class="col-xs-12 col-sm-8">
            <input  class="form-control" type="text" name="row[work_no]" value="{$task.work_no}">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('工程費')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-price" data-rule="required" class="form-control" name="row[price]" type="text" value="{$price}">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Message')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-message" class="form-control " rows="5" name="row[message]" cols="50"></textarea>
        </div>
    </div>


    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button id="c-submit" type="button" class="btn btn-success btn-embossed" style="width: 200px" >{:__('OK')}</button>
            <!--<button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>-->
        </div>
    </div>
</form>
